package edu.bit.water.dao;

import edu.bit.water.entity.EvaWaterSensorInfo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.dao.DataIntegrityViolationException;
import org.springframework.dao.DuplicateKeyException;
import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Map;

@Mapper
@Repository
public interface EvaWaterSensorInfoDao {
    //查询表中所有记录
    List<EvaWaterSensorInfo> queryEvaWaterSensorInfoByCompanyId(int company_id,int currentUserId);
    //删除
    void deleteEvaWaterSensorInfo(@Param ("idList")String s);
    int deleteEvaWaterSensorInfoByCompanyId(int company_id);
    //插入值
    int insertEvaWaterSensorInfo(EvaWaterSensorInfo evaWaterSensorInfo)throws DuplicateKeyException;
    //更新
    int updateEvaWaterSensorInfo(EvaWaterSensorInfo evaWaterSensorInfo)throws DuplicateKeyException;
    //查询technological_process表中相同名字的公司且模块为设备管理的公司id方便用于设备查询
    int query_entity_sensor_cid(int testId);
}
